import 'package:labcloud_app/data/product.dart';

class UserCart {

  UserCart({
    this.id,
    this.userId,
    this.productId,
    this.quantity,
    this.createTime,
    this.updateTime,
    this.product,
  });
  String? id;
  String? userId;
  String? productId;
  num? quantity;
  String? createTime;
  String? updateTime;
  Product? product;
}

class UserCartItems {
  UserCartItems({
      this.id, 
      this.userId, 
      this.productId, 
      this.quantity, 
      this.createTime, 
      this.updateTime,
  });

  UserCartItems.fromJson(dynamic json) {
    id = json['id'];
    userId = json['userId'];
    productId = json['productId'];
    quantity = json['quantity'];
    createTime = json['createTime'];
    updateTime = json['updateTime'];
  }
  String? id;
  String? userId;
  String? productId;
  num? quantity;
  String? createTime;
  String? updateTime;

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['id'] = id;
    map['userId'] = userId;
    map['productId'] = productId;
    map['quantity'] = quantity;
    map['createTime'] = createTime;
    map['updateTime'] = updateTime;
    return map;
  }
}